import Http, {HttpParamsProps, ReqProps} from "@/common/http";
import {BaseEntitys} from "@/common/httptypes";


//后期需整改数据-没用的删掉
export type SyBankEntity = {
  id: string
  bankName?: string
  contacts?: string
  contactsPhone?: string
  del?: boolean
  deptId?: string
} & BaseEntitys

class CoopBank {
    RowKey = "id"
    EDIT = "bankEdit"
    ADD = "bankAdd"
    DEL = "bankDelete"
    
    MAPPING = {bankEdit: "编辑银行", bankAdd: "新增银行"}


    selectTablePage(props: HttpParamsProps): Promise<Response> {
        return Http.get("/blank/select", props)
    }

    doEdit(props: ReqProps<void>) {
        Http.doPost("/blank/updateById", props)
    }
    doSave(props: ReqProps<void>) {
        Http.doPost("/blank/save", props)
    }

    delete(props: ReqProps<void>) {
        Http.doDelete("/blank/deleteById", props)
    }

}

// eslint-disable-next-line import/no-anonymous-default-export
export default new CoopBank()